home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / c / tick.zip / TICK.H < prev   
C/C++ Source or Header  |  1988-03-08  |  1KB  |  52 lines

  1. /*    tick.h - the include file for timer and c_brk function installation */
  2. /*    (c) - Amit Joshi, Princeton University 
  3.  
  4.     This code may be used freely for any noncommercial use. It may NOT
  5.     be used in any commercial package without written permission from
  6.     the author. This clause is to protect me from legal hassles with
  7.     the university about code developed here. This code is supplied
  8.     "AS IS" i.e. with no warranty. Do not remove this notice. Any 
  9.     modifications should be clearly noted before redistribution.
  10. **/
  11.  
  12. /**    Amit Joshi
  13.     MAE Dept., Engg. Quad.
  14.     Princeton University
  15.     December 1987
  16. **/
  17.  
  18. /**
  19.     Change the values defined for NTIMERS and NCBRKS to increase 
  20.     number of timer and cbrk functions installed.
  21.  
  22.     Amit Joshi
  23.     January 1988
  24. **/
  25.  
  26. #ifndef    __TICK_H__
  27. #define    __TICK_H__
  28.  
  29. #include <dos.h>
  30.  
  31. /* Change the following definitions to increase number of timers and cbrks */
  32. #define    NTIMERS    2    /* number of timers installable */
  33. #define    NCBRKS    2    /* number of cbrks installable */
  34.  
  35. #define NULLIVFP    (void interrupt (*)())NULL
  36. #define    NULLVFP        (void (*)())NULL
  37. #define NULLFP        (int (*)())NULL 
  38.  
  39. #ifdef    HARDTIMER
  40. #define    TIMER_INT    0x08
  41. #else
  42. #define TIMER_INT    0x1C     
  43. #endif
  44.  
  45. /* user callable functions */
  46. int    _Cdecl        install_timer(void (*func)());    
  47. int    _Cdecl        install_cbrk(void (*func)());
  48. int    _Cdecl        remove_timer(void (*func)());
  49. int    _Cdecl        remove_cbrk(void (*func)());
  50.  
  51. #endif    __TICK_H__
  52.